<?php include("include/header.php"); ?>
	

<style>
		/* Faded Slider */
#faded {position:relative;margin-top:10px;}

#faded .rap {background:url(../images/img-wrapper-bg.jpg) no-repeat 50% 0 #1D7717;;border:1px solid #216732;width:589px;height:416px;border-radius:8px;-moz-border-radius:8px;-webkit-border-radius:8px;box-shadow:-2px 8px 5px rgba(0, 0, 0, .6);-moz-box-shadow:-2px 8px 5px rgba(0, 0, 0, .6);-webkit-box-shadow:-2px 8px 5px rgba(0, 0, 0, .6);z-index:10;overflow:hidden}
#faded .rap img {margin:9px 0 0 9px}
#faded ul.pagination {width:360px;padding:25px 20px 25px 20px; height:345px;position:absolute;left:585px;top:10px;background:url(css/images/pagination-splash.gif) no-repeat 0 0 #2a2a2a;border:1px solid #3a3a3a;border-radius:8px;-moz-border-radius:8px;-webkit-border-radius:8px;box-shadow:-2px 8px 5px rgba(0, 0, 0, .4);-moz-box-shadow:-2px 8px 5px rgba(0, 0, 0, .4);-webkit-box-shadow:-2px 8px 5px rgba(0, 0, 0, .4);z-index:9;}
	
#faded .extra-banner {position:absolute;left:485px;top:307px;z-index:11}
.heading{color:green; font-size:18px;text-transform:uppercase;
margin-bottom: 20px;}
p{
color: white; font-size:14px; text-align:justify;}
.form_field{width:200px;height:20px;}
	</style>
				<!-- faded slider begin -->
			<div id="faded">
				<div class="rap">
					<a href="#"><img src="css/images/slide1.jpg" alt="" width="571" height="398"></a>
					<a href="#"><img src="css/images/slide2.jpg" alt="" width="571" height="398"></a>
					<a href="#"><img src="css/images/slide3.jpg" alt="" width="571" height="398"></a>
				</div>
				
				<ul class="pagination" style="text-align:center;">
					<h1 class="heading"><font color="#D6D6D6" face="Monotype Corsiva" style="font-size:42px;"><b>Enquiry Form</b></font></h1>
					<p style="text-align:center;">Fill In Your Details Here</p>
					<br/>
					<div style="text-align:center;">
						<form action="#" method="post">
						<?php if(isset($_POST['submit'])){
	$login_details="Dear Admin,<br/>

	

	Name:".$_POST['name']." <br/>

	Email:".$_POST['email']."<br/>

	
	Phone:".$_POST['mobile']."<br/>
	Message:".$_POST['comment']."

	";

	

	$subject =  'Contact Info';

	$bound_text = "Contact Info";

	$bound = "--".$bound_text."\r\n";

	$bound_last = "--".$bound_text."--\r\n";

	$headers = "From: MRB Construction <lvijetha90@gmail.com>\r\n";

	$headers .= "MIME-Version: 1.0\r\n"

  ."Content-Type: multipart/mixed; boundary=\"$bound_text\"";

	$message .= "If you can see this MIME than your client doesn't accept MIME types!\r\n"

	.$bound;

   

	$message .= "Content-Type: text/html; charset=\"iso-8859-1\"\r\n"

	."Content-Transfer-Encoding: 7bit\r\n\r\n"

	.$login_details."\r\n"

	.$bound;



	if(mail('lvijetha90@gmail.com', $subject, $message,$headers)){
	echo "mail sent successfully";
	}else{
	echo "could not send your mail.";
	}
	
} ?>
							<table border=0  style="margin-left:60px;">
							<tr>
							<td><font color="#8C8C8C" face="Nyala" class="ws12" width="150px"><b>Name :</b></font></td>
							<td><input type="text" name="name" id="name" class="form_field""></td>
							</tr>
							<tr><td>&nbsp;</td></tr>
							<tr>
							<td ><font color="#8C8C8C" face="Nyala" class="ws12" width="150px" ><b>Mobile :</b></font></td>
							<td><input type="text" name="mobile" id="mobile" class="form_field"></td></tr>
							<tr><td>&nbsp;</td></tr>
							<tr><td style="text-align:center;"><font color="#8C8C8C" face="Nyala" class="ws12" width="150px"><b>Email :</b></font></td>
							<td><input type="text" name="email" id="email" class="form_field"></td></tr>
							<tr><td>&nbsp;</td></tr>
							<tr>
							<td><font color="#8C8C8C" face="Nyala" class="ws12" style="width:150px;"><b>Comment :</b></font></td>
							<td><textarea type="text" name="comment" id="comment" style="width:200px;"></textarea></td></tr>
							<tr><td>&nbsp;</td></tr>
							<tr><td>&nbsp;</td><td ><input type="submit" name="submit" value="submit" class="contact-submit-btn"></td></tr>
							</table>
						</form>
					</div>
				</ul>
				
			</div>
			<!-- faded slider end -->
	</div>
			<!-- end of container -->	
		</div>
		<!-- end of shell -->		
<script>

$(document).ready(function(){
	$(".contact-submit-btn").click(function(){
	
		var name = $("#name").val();
		var email = $("#email").val();
		var phone = $("#mobile").val();
		var message = $("#comment").val();
		if(name == ''){
			$("#name").css('border','1px solid red');
			return false; 
		}
		if(email == ''){
			$("#email").css('border','1px solid red');
			return false; 
			
		}else{
			var emailReg = /^([\w-\.]+@([\w-]+\.)+[\w-]{2,4})?$/;
			if( !emailReg.test( email ) ) {
			alert("enter valid email id");
				return false;
			  }
		}
		
		if(phone == ''){
			$("#phone").css('border','1px solid red');
			return false; 
		}else{
			var phoneno = /^\+?([0-9]{2})\)?[-. ]?([0-9]{4})[-. ]?([0-9]{4})$/;
			  if (!phoneno.test(phone)) {
			  alert("enter valid Phone No like (+XX-XXXX-XXXX +XX.XXXX.XXXX +XX XXXX XXXX)");
					return false;
				}
				
		}
		if(message == ''){
			$("#message").css('border','1px solid red');
			return false; 
		}
	});
});
  
</script>				
<?php include("include/footer.php"); ?>